<%
    /*
     * Folder_Content.jsp
     * Copyright 2001 MicroStrategy Incorporated. All rights reserved.
     */
%>

<%@ page errorPage="Error_Content.jsp"%>
<%@ page contentType="text/html; charset=UTF-8"%>
<%@ taglib uri="/webUtilTL.tld" prefix="web"%>
<web:resource type="javascript" name="leftToolbar.js"/>
<web:resource type="javascript" name="mstrLeftPaneImpl.js"/>
<web:resource type="javascript" name="mstrMenuTabsImpl.js"/>

<STYLE TYPE="text/css">
        #leftToolbar,
        .mscld-fldr-menu,
        .mstrVerticalDocks .tdDockLeft {
            width: <web:ifFeature type="browserSetting" name="lTbar" value="0"><web:then>34px</web:then><web:else><web:value type="browserSetting" name="ltW"/>px</web:else></web:ifFeature>;
        }
        #dhtml_statistics {
            margin-left: <web:ifFeature type="browserSetting" name="lTbar" value="0"><web:then>34px</web:then><web:else><web:value type="browserSetting" name="ltW"/>px</web:else></web:ifFeature>;
        }
</STYLE> 

<%-- Create tab --%>
<web:ifFeature name="create-objects"><web:then>
<div id=mstrCreatePopup class="mstrMenuSection">
    <div class="mstrMenuContent" ty="content">
        <web:shortcutOptions type="create" shortcutClass="mstrMenuItem" shortcutSelectedClass="mstrMenuItem">
            <web:shortcutElement />
        </web:shortcutOptions>
    </div>
</div>
</web:then></web:ifFeature>

<div id="leftToolbar" scriptclass="mstrLeftPaneImpl" rsz="2" >
	<div class="mstrMenuTabs <web:ifFeature type="browserSetting" name="lTbar" value="0"><web:then>collapsed</web:then></web:ifFeature> " id="menuTabs" scriptclass="mstrMenuTabsImpl">
	    <div id="menuToggler" class="mstrMenuTab toggler" ty='btn'><div class="icon-toggle">&nbsp;</div></div>
		<web:ifFeature name="dhtml;create-analysis">
			<web:then>
                <div id="mscld-create" class="mscld-create analysis" <web:descriptor attribute="title" key="mstrWeb.11114" desc="Create a quick analysis or dashboard from imported or existing data." />>
                    <div id="mscld-create-label" class="mscld-create-label"><web:descriptor key="mstrWeb.9929" desc="New Dashboard" /></div>
                    <a href="#" onclick="microstrategy.createIVE();" class="mscld-create-lnk"></a>				
                </div>
			</web:then>
			<web:else>
			    <web:ifFeature name="create-view-reports">
			        <web:then>
					    <div id="mscld-create" class="mscld-create report" <web:descriptor attribute="title" key="mstrWeb.9930" desc="New Report" />>
					       <div id="mscld-create-label" class="mscld-create-label"><web:descriptor key="mstrWeb.9930" desc="New Report" /></div>
					       <web:urlEvent eventID="com.microstrategy.web.app.beans.EnumServletEvents.WebEventOpenCreate" linkAttributes ="class='mscld-create-lnk'"> </web:urlEvent>
					    </div>
			        </web:then>
			        <web:else>
					    <web:ifFeature name="template-documents;dhtml;documents-design-mode">
					        <web:then>
				                <div id="mscld-create" class="mscld-create rwd" <web:descriptor attribute="title" key="mstrWeb.5898" desc="New Document" />>
				                  <div id="mscld-create-label" class="mscld-create-label"><web:descriptor key="mstrWeb.5898" desc="New Document" /></div>
						          <web:urlEvent eventID="com.microstrategy.web.app.beans.EnumServletEvents.WebEventOpenCreateDocument" linkAttributes ="class='mscld-create-lnk'"> </web:urlEvent>
				                </div>
					        </web:then>
					    </web:ifFeature>
			        </web:else>
			    </web:ifFeature>
			</web:else>
		</web:ifFeature>
		<%-- Browse tab --%>
		<div class="mstrMenuSection">
			<div class="mstrMenuContent" ty="content">
			    <web:ifFeature name="dhtml"><web:then>
			      <web:ifFeature name="create-objects"><web:then>
					  <span class="mstrMenuItemcreate mstrMenuItem"><span id="mscld-create-menu" class="mscld-create-menu">
					    <web:descriptor key="mstrWeb.3291" desc="Create" />...
					  </span></span>
				  </web:then></web:ifFeature>
				</web:then></web:ifFeature>
			    <web:ifBeanValue property="getName" value="search">
	              <web:then>
	                <web:ifFeature name="dhtml">
                      <web:then>
				        <span class="mstrMenuItemsearch mstrMenuItem mstrMenuItemSelected" ty="toggler" target="search_options"><web:descriptor key="mstrWeb.10" desc="Search" /></span>
                        <jsp:include page='/jsp/Advanced_Search.jsp' flush="true" />
                      </web:then>
                    </web:ifFeature>
	              </web:then>
	              <web:else>
				    <web:ifFeature name="object-search"><web:then>
				      <span class="mstrMenuItemsearch mstrMenuItem">
				        <web:urlEvent eventID="com.microstrategy.web.app.beans.EnumServletEvents.WebEventOpenSearch">
				          <web:descriptor key="mstrWeb.10" desc="Search" />
				        </web:urlEvent>
				      </span>
				    </web:then></web:ifFeature>
	              </web:else>
	            </web:ifBeanValue>
	            <web:ifFeature name="dhtml">
		            <web:then>
					    <web:ifBeanValue property="getName" value="my">
			               <web:then>
					         <web:displayGuiComponent name="folder_tree"/>  
					       </web:then>
		                <web:else>
		                  <web:ifBeanValue property="getName" value="shared">
		                   <web:then>
		                     <web:displayGuiComponent name="folder_tree"/>  
		                   </web:then>
		                  </web:ifBeanValue>
		                </web:else>
		                </web:ifBeanValue>
		            </web:then>
	            </web:ifFeature>
                
				<web:shortcutOptions type="toolbar" shortcutClass="mstrMenuItem" shortcutSelectedClass="mstrMenuItemSelected">
				    <web:shortcutElement />
		        </web:shortcutOptions>
		        <web:ifFeature name="preferences"><web:then>
			        <web:shortcutOptions type="tools" shortcutClass="mstrMenuItem" shortcutSelectedClass="mstrMenuItem">
	                    <web:shortcutElement />
	                </web:shortcutOptions>
                </web:then></web:ifFeature>
			</div>
	        <web:ifBeanValue bean="leftTbExtraOpt">
			  <web:then>
			     <div class="mstrMenuExtra" ty="extraOpt">
			         <web:displayBean bean="leftTbExtraOpt" />
		         </div>
		      </web:then>
		   </web:ifBeanValue>
		</div>
	</div>
</div>

<STYLE TYPE="text/css">
	.mstrDHTML .mstrVerticalDocks {table-layout:fixed;}
	.mstrDHTML .mstrDockLeft {position: fixed;}
    .mstrDHTML .mstrDockLeft {
        border-right: 1px solid #aaa;
        height: 100%;
    }
        .mstrContent {
          margin-right: 15px;
        }
        div[id="mstrWeb_content"] {
          margin-right: 0px;
        }
        .mscld-fldr-menu,
        .mstrVerticalDocks .tdDockLeft {
        	-webkit-transition: width 300ms;
        	-moz-transition: width 300ms;
        	padding:0px;
        }
        #leftToolbar {
            overflow:hidden;
        }
        .tdDockLeft {
             background-color:#f5f5f5;
        }
        .mscld-fldr-menu {
        background-position:right -36px;
        }
        <web:ifFeature name="dhtml">
          <web:then>
            .mstrMenuExtra {
        	  display:none;
            }
          </web:then>
          <web:else>
            body.mstrHTML {
              overflow: visible;
            }
          </web:else>
        </web:ifFeature>
        <web:ifFeature name="IE">
          <web:then>
            #folderAllModes .mstrListView {position:static;}            
          </web:then>
        </web:ifFeature>
        <web:ifFeature name="IE7">
          <web:then>
            .mstrContent {position: relative;}
          </web:then>
        </web:ifFeature>
        .mstrDockLeft {
            display:block !important;
        } <%-- dispaly the tree --%>
        .mstrProjectHeader {
            margin: 5px;
        }
        </STYLE> 

<script language="javascript">
if (typeof(microstrategy) != 'undefined') {
    microstrategy.registerBone("menuTabs", (true), {});
    microstrategy.registerBone("leftToolbar", (true), { 'ltW' : '<web:value type="browserSetting" name="ltW"/>'});
}
</script>



